## Loading required package: zoo
## 
## Attaching package: 'zoo'
## The following objects are masked from 'package:base':
## 
##     as.Date, as.Date.numeric
## ── Attaching packages ─────────────────────────────────────── tidyverse 1.3.2 ──
## ✔ ggplot2 3.4.0      ✔ purrr   0.3.5 
## ✔ tibble  3.1.8      ✔ dplyr   1.0.10
## ✔ tidyr   1.2.1      ✔ stringr 1.4.1 
## ✔ readr   2.1.3      ✔ forcats 0.5.2 
## ── Conflicts ────────────────────────────────────────── tidyverse_conflicts() ──
## ✖ dplyr::between()   masks data.table::between()
## ✖ dplyr::filter()    masks stats::filter()
## ✖ dplyr::first()     masks data.table::first()
## ✖ dplyr::lag()       masks stats::lag()
## ✖ dplyr::last()      masks data.table::last()
## ✖ purrr::transpose() masks data.table::transpose()
## 
## Please cite as: 
## 
## 
##  Hlavac, Marek (2022). stargazer: Well-Formatted Regression and Summary Statistics Tables.
## 
##  R package version 5.2.3. https://CRAN.R-project.org/package=stargazer 
## 
## 
## 
## Attaching package: 'gridExtra'
## 
## 
## The following object is masked from 'package:dplyr':
## 
##     combine

Participant Information

Here, we examine participant demographics, such as their age and gender, in addition to information about their work industry and experience. Overall, our sample is highly skewed in terms of gender. A representative average participant would be a man who works in a relatively large technology company with some years of experience.

## `stat_bin()` using `bins = 30`. Pick better value with `binwidth`.

## Selecting by ct

Covariate checks between conditions

ggplot(pt_info, aes(x = age))+
  geom_histogram(bins = 30, aes(fill = Condition), alpha = 0.8)+
  scale_fill_manual(values = color_scheme)+
  labs(title = "Distribution of Participant Age",
       subtitle = "Age was relatively similar across conditions.",
       x = "Age",
       y = "Count")+
  facet_grid(Condition ~ .)+
  theme(strip.text.y = element_text(angle = 0))

pt_info %>% 
  group_by(Condition) %>% 
  summarise(avg_age = mean(age))
## # A tibble: 4 × 2
##   Condition            avg_age
##   <chr>                  <dbl>
## 1 Man_Nontraditional      38.7
## 2 Man_Traditional         39.3
## 3 Woman_Nontraditional    41.4
## 4 Woman_Traditional       38.9
ggplot(pt_info, aes(x = as.factor(gender)))+
  geom_bar(stat = "count", position= "dodge", aes(fill = Condition), alpha = 0.8)+
  scale_fill_manual(values = color_scheme)+
  scale_x_discrete(limits = c("Man", "Woman", "Non-binary / third gender", "Prefer not to say"))+
  labs(title = "Distribution of Participant Gender and Condition",
       subtitle = "Gender was relatively similar across conditions.",
       x = "Reported Gender",
       y = "Count")

industry_dist <- ggplot(industry_df %>% top_n(10) , aes(x = factor(industry, levels = industry), y  = ct))+
  geom_bar(stat = "identity", aes(fill = Condition), alpha = 0.8)+
  scale_fill_manual(values = color_scheme)+
  theme(axis.text.x = element_text(angle = 90, vjust = 0.5, hjust=1))+
  labs(title = "Distribution of Participant Industry", 
       subtitle = paste0(
         round(subset(industry_df, industry == "Technology")$ct / nrow(pt_info), 2) * 100,
         "% of participants work in Tehcnology"
       ),
       x = "Industry Area",
       y = "Count")
## Selecting by ct
ggplot(pt_info, aes(x = factor(str_replace_all(company_size, " employees", ""),
                               levels = c("Less than 50",
                                          "50-100",
                                          "100-500",
                                          "500-1,000",
                                          "1,000+"))))+
  geom_bar(stat = "count", position = "dodge", aes(fill = Condition), alpha = 0.8)+
  scale_fill_manual(values = color_scheme)+
  labs(title = "Distribution of Participant Company Size",
       subtitle = "Number of employees",
       x = "Company Size",
       y = "Count")

chisq.test(pt_info$company_size, pt_info$Condition)
## 
##  Pearson's Chi-squared test
## 
## data:  pt_info$company_size and pt_info$Condition
## X-squared = 7.8454, df = 12, p-value = 0.7971
ggplot(pt_info, aes(x = factor(experience,
                               levels = c("Less than 1 year",
                                          "1-2 years",
                                          "3-5 years",
                                          "5-10 years",
                                          "10+ years"))))+
  geom_bar(stat = "count", aes(fill = Condition), position = "dodge", alpha = 0.8)+
  scale_fill_manual(values = color_scheme)+
  labs(title = "Distribution of Participant Work Experience",
       subtitle = "",
       x = "Years of Experience",
       y = "Count")

chisq.test(pt_info$experience, pt_info$Condition)
## 
##  Pearson's Chi-squared test
## 
## data:  pt_info$experience and pt_info$Condition
## X-squared = 6.2959, df = 12, p-value = 0.9004
ggplot(pt_info, aes(x = risk))+
  geom_bar(stat = "count", aes(fill = Condition), alpha = 0.8)+
  scale_fill_manual(values = color_scheme)+
  labs(title = "Distribution of Participant Risk Aversion",
       x = "Average Response to Risk Items",
       y = "Count")+
  facet_grid(Condition ~.)+
  theme(strip.text.y = element_text(angle = 0))

pt_info_dt <- data.table(pt_info)

# check for gender treatment
pt_info_dt[, applicant_gender_bin := ifelse(Condition == "Man_Traditional" | Condition == "Man_Nontraditional", 
                                            0, 1)]
null_gender_mod <- pt_info_dt[, lm(applicant_gender_bin ~ 1)]
full_gender_mod <- pt_info_dt[ , lm(applicant_gender_bin ~ 1 + 
                                      age + 
                                      gender + 
                                      company_size + 
                                      factor(experience,
                                             levels = c("Less than 1 year",
                                                        "1-2 years",
                                                        "3-5 years",
                                                        "5-10 years",
                                                        "10+ years"))+
                                      factor(str_replace_all(company_size, " employees", ""),
                                             levels = c("Less than 50",
                                                        "50-100",
                                                        "100-500",
                                                        "500-1,000",
                                                        "1,000+"))
)]
anova(null_gender_mod, full_gender_mod)
## Analysis of Variance Table
## 
## Model 1: applicant_gender_bin ~ 1
## Model 2: applicant_gender_bin ~ 1 + age + gender + company_size + factor(experience, 
##     levels = c("Less than 1 year", "1-2 years", "3-5 years", 
##         "5-10 years", "10+ years")) + factor(str_replace_all(company_size, 
##     " employees", ""), levels = c("Less than 50", "50-100", "100-500", 
##     "500-1,000", "1,000+"))
##   Res.Df    RSS Df Sum of Sq     F Pr(>F)
## 1    299 74.997                          
## 2    287 71.967 12    3.0301 1.007 0.4424
# check for education treatment
pt_info_dt[, applicant_education_bin := ifelse(Condition == "Man_Traditional" | Condition == "Woman_Traditional", 
                                            0, 1)]
null_education_mod <- pt_info_dt[, lm(applicant_education_bin ~ 1)]
full_education_mod <- pt_info_dt[, lm(applicant_education_bin ~ 1 + 
                                      age + 
                                      gender + 
                                      company_size + 
                                      factor(experience,
                                             levels = c("Less than 1 year",
                                                        "1-2 years",
                                                        "3-5 years",
                                                        "5-10 years",
                                                        "10+ years"))+
                                      factor(str_replace_all(company_size, " employees", ""),
                                             levels = c("Less than 50",
                                                        "50-100",
                                                        "100-500",
                                                        "500-1,000",
                                                        "1,000+"))
)]
anova(null_education_mod, full_education_mod)
## Analysis of Variance Table
## 
## Model 1: applicant_education_bin ~ 1
## Model 2: applicant_education_bin ~ 1 + age + gender + company_size + factor(experience, 
##     levels = c("Less than 1 year", "1-2 years", "3-5 years", 
##         "5-10 years", "10+ years")) + factor(str_replace_all(company_size, 
##     " employees", ""), levels = c("Less than 50", "50-100", "100-500", 
##     "500-1,000", "1,000+"))
##   Res.Df    RSS Df Sum of Sq      F Pr(>F)
## 1    299 75.000                           
## 2    287 73.551 12    1.4489 0.4711 0.9306
# check for interaction treatment
pt_info_dt[, applicant_interaction_bin := ifelse(Condition == "Woman_Nontraditional", 
                                            1, 0)]
null_interaction_mod <- pt_info_dt[, lm(applicant_interaction_bin ~ 1)]
full_interaction_mod <- pt_info_dt[, lm(applicant_interaction_bin ~ 1 + 
                                      age + 
                                      gender + 
                                      company_size + 
                                      factor(experience,
                                             levels = c("Less than 1 year",
                                                        "1-2 years",
                                                        "3-5 years",
                                                        "5-10 years",
                                                        "10+ years"))+
                                      factor(str_replace_all(company_size, " employees", ""),
                                             levels = c("Less than 50",
                                                        "50-100",
                                                        "100-500",
                                                        "500-1,000",
                                                        "1,000+"))
)]
anova(null_interaction_mod, full_interaction_mod)
## Analysis of Variance Table
## 
## Model 1: applicant_interaction_bin ~ 1
## Model 2: applicant_interaction_bin ~ 1 + age + gender + company_size + 
##     factor(experience, levels = c("Less than 1 year", "1-2 years", 
##         "3-5 years", "5-10 years", "10+ years")) + factor(str_replace_all(company_size, 
##     " employees", ""), levels = c("Less than 50", "50-100", "100-500", 
##     "500-1,000", "1,000+"))
##   Res.Df    RSS Df Sum of Sq      F Pr(>F)
## 1    299 56.250                           
## 2    287 52.968 12     3.282 1.4819   0.13

Summary Stats

Here, we examine some basic information about how ratings for different applicants varied.

average_ratings <- analysis %>% 
  group_by(Condition) %>% 
  summarise(avg_rating = mean(rating),
            standard_dev = sd(rating),
            max = avg_rating+ standard_dev,
            min = avg_rating - standard_dev,
            n = n())
average_ratings
## # A tibble: 4 × 6
##   Condition            avg_rating standard_dev   max   min     n
##   <fct>                     <dbl>        <dbl> <dbl> <dbl> <int>
## 1 Man_Traditional            7.60         1.47  9.07  6.14   243
## 2 Man_Nontraditional         7.18         1.99  9.17  5.19   258
## 3 Woman_Traditional          7.93         1.51  9.44  6.42   202
## 4 Woman_Nontraditional       7.21         1.79  9.01  5.42   242
gender_ratings <- analysis %>% 
  group_by(applicant_gender) %>% 
  summarise(avg_rating = mean(rating),
            standard_dev = sd(rating))
gender_ratings
## # A tibble: 2 × 3
##   applicant_gender avg_rating standard_dev
##   <fct>                 <dbl>        <dbl>
## 1 man                    7.39         1.77
## 2 woman                  7.54         1.71
education_ratings <- analysis %>% 
  group_by(applicant_education) %>% 
  summarise(avg_rating = mean(rating),
            standard_dev = sd(rating))
education_ratings
## # A tibble: 2 × 3
##   applicant_education avg_rating standard_dev
##   <fct>                    <dbl>        <dbl>
## 1 trad                      7.75         1.49
## 2 nontrad                   7.19         1.90
ggplot(analysis, aes(x = rating))+
  geom_density(stat = "count",aes(fill = Condition), alpha = 0.8)+
  scale_fill_manual(values = color_scheme)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Traditional")$rating), color = w_t)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Traditional")$rating), color = m_t)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Nontraditional")$rating), color = w_nt, linewidth = 1.25)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Nontraditional")$rating), color = m_nt)+
  geom_vline(xintercept = 5, color = lightgray)+
  labs(title = "Distribution of Participant Ratings by Condition",
       #       subtitle = "Vertical lines indicates average rating",
       x = "Rating",
       y = "Count")

ggplot(analysis, aes(x = rating))+
  geom_bar(stat = "count", aes(fill = Condition))+
  scale_fill_manual(values = color_scheme)+
  facet_grid(Condition ~ .)+
  labs(title = "Rating Distributions by Condition",
       x = "Rating",
       y = "Count")+
  theme(strip.text.y = element_text(angle = 0),
        legend.position = "none")

ggplot(analysis, aes(x = rating, y = Condition))+
  scale_y_discrete(limits = c("Man_Traditional", "Man_Nontraditional", "Woman_Traditional", "Woman_Nontraditional"))+
  geom_jitter(aes(color = Condition))+
  scale_fill_manual(values = color_scheme)+
  scale_color_manual(values = color_scheme)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Traditional")$rating), color = w_t, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Traditional")$rating), color = m_t, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Nontraditional")$rating), color = w_nt, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Nontraditional")$rating), color = m_nt, linewidth = 1.5, alpha = 0.5)+
  geom_hline(yintercept = 5, color = lightgray, linewidth = 1.25)+
  theme(legend.position = "none")+
  labs(title = "Distribution of Ratings by Condition",
       x = "Rating")

## technical scale
ggplot(analysis, aes(x = technical_scale, y = Condition))+
  geom_jitter(aes(color = Condition))+
  scale_fill_manual(values = color_scheme)+
  scale_color_manual(values = color_scheme)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Traditional")$technical_scale), color = w_t, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Traditional")$technical_scale), color = m_t, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Nontraditional")$technical_scale), color = w_nt, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Nontraditional")$technical_scale), color = m_nt, linewidth = 1.5)+
  labs(title = "Technical Scale Ratings",
       x = "Rating",
       y = "Condition")+
  theme(legend.position = "none", plot.title = element_text(size=22), axis.text.y=element_blank())

## leadership scale
ggplot(analysis, aes(x = leadership_scale, y = Condition))+
  geom_jitter(aes(color = Condition))+
  scale_fill_manual(values = color_scheme)+
  scale_color_manual(values = color_scheme)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Traditional")$leadership_scale), color = w_t, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Traditional")$leadership_scale), color = m_t, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Nontraditional")$leadership_scale), color = w_nt, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Nontraditional")$leadership_scale), color = m_nt, linewidth = 1.5)+
  labs(title = "Leadership Scale Ratings",
       x = "Rating",
       y = "Condition")+
  theme(legend.position = "none", plot.title = element_text(size=22), axis.text.y=element_blank())

## likeable scale
ggplot(analysis, aes(x = likeable_scale, y = Condition))+
  geom_jitter(aes(color = Condition))+
  scale_fill_manual(values = color_scheme)+
  scale_color_manual(values = color_scheme)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Traditional")$likeable_scale), color = w_t, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Traditional")$likeable_scale), color = m_t, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Nontraditional")$likeable_scale), color = w_nt, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Nontraditional")$likeable_scale), color = m_nt, linewidth = 1.5)+
  labs(title = "Likeable Scale Ratings",
       x = "Rating",
       y = "Condition")+
  theme(legend.position = "none", plot.title = element_text(size=22), axis.text.y=element_blank())

## learner scale
ggplot(analysis, aes(x = learner_scale, y = Condition))+
  geom_jitter(aes(color = Condition))+
  scale_fill_manual(values = color_scheme)+
  scale_color_manual(values = color_scheme)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Traditional")$learner_scale), color = w_t, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Traditional")$learner_scale), color = m_t, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Nontraditional")$learner_scale), color = w_nt, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Nontraditional")$learner_scale), color = m_nt, linewidth = 1.5)+
  labs(title = "Learner Scale Ratings",
       x = "Rating",
       y = "Condition")+
  theme(legend.position = "none", plot.title = element_text(size=22), axis.text.y=element_blank())

## education scale
ggplot(analysis, aes(x = education_scale, y = Condition))+
  geom_jitter(aes(color = Condition))+
  scale_fill_manual(values = color_scheme)+
  scale_color_manual(values = color_scheme)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Traditional")$education_scale), color = w_t, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Traditional")$education_scale), color = m_t, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Nontraditional")$education_scale), color = w_nt, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Nontraditional")$education_scale), color = m_nt, linewidth = 1.5)+
  labs(title = "Education Scale Ratings",
       x = "Rating",
       y = "Condition")+
  theme(legend.position = "none", plot.title = element_text(size=22), axis.text.y=element_blank())

## experience scale
ggplot(analysis, aes(x = experience_scale, y = Condition))+
  geom_jitter(aes(color = Condition))+
  scale_fill_manual(values = color_scheme)+
  scale_color_manual(values = color_scheme)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Traditional")$experience_scale), color = w_t, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Traditional")$experience_scale), color = m_t, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Woman_Nontraditional")$experience_scale), color = w_nt, linewidth = 1.5)+
  geom_vline(xintercept = mean(subset(analysis, Condition == "Man_Nontraditional")$experience_scale), color = m_nt, linewidth = 1.5)+
  labs(title = "Experience Scale Ratings",
       x = "Rating",
       y = "Condition")+
  theme(legend.position = "none", plot.title = element_text(size=22), axis.text.y=element_blank())

Testing

d <- data.table(analysis)
d <- d[gender == "Man" | gender == "Woman"]

ANOVA

## anova testing
summary(d[, aov(rating ~ Condition)])
##              Df Sum Sq Mean Sq F value   Pr(>F)    
## Condition     3  105.8   35.28   12.02 1.01e-07 ***
## Residuals   912 2677.0    2.94                     
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## follow-up t-tests, holm correction
d[, pairwise.t.test(rating, Condition, p.adjust.method = "bonferroni")]
## 
##  Pairwise comparisons using t tests with pooled SD 
## 
## data:  rating and Condition 
## 
##                      Man_Traditional Man_Nontraditional Woman_Traditional
## Man_Nontraditional   0.0222          -                  -                
## Woman_Traditional    0.2931          1.5e-05            -                
## Woman_Nontraditional 0.0037          1.0000             1.6e-06          
## 
## P value adjustment method: bonferroni

Based on the previous tests, we can detect that there are significant differences between conditions. This result is shown in the ANOVA test, for which post hoc testing indicates differences between the Woman_Traditional condition and the conditions Man_Nontraditional and Woman_Nontraditional. We follow this testing with linear models to more clearly capture the quantitative differences between ratings.

No Covariates - Baseline Model

The previous analysis focused specifically on the conditions shown. We are also interested in the qualities of these conditions, such as the applicant_gender & applicant_education variables. This will give us a clearer statistical understanding of the input of each quality of the applicant. At this point forward, we use linear models, rather than ANOVA and t-testing. This is to make the content more consistent with the techniques learned in the course.

m1 <- d[, lm(rating ~ applicant_gender * applicant_education)]

# test for heteroscedasticity to determine if use of robust standard errors is justified
plot(m1)

bptest(m1)
## 
##  studentized Breusch-Pagan test
## 
## data:  m1
## BP = 20.086, df = 3, p-value = 0.0001629
m1$vcovHC_ <- vcovHC(m1)
coefs_applicants <- coeftest(m1, vcov. = m1$vcovHC_)
coefs_applicants
## 
## t test of coefficients:
## 
##                                                   Estimate Std. Error t value
## (Intercept)                                       7.604938   0.094417 80.5462
## applicant_genderwoman                             0.323996   0.143717  2.2544
## applicant_educationnontrad                       -0.447458   0.157028 -2.8495
## applicant_genderwoman:applicant_educationnontrad -0.422917   0.225062 -1.8791
##                                                   Pr(>|t|)    
## (Intercept)                                      < 2.2e-16 ***
## applicant_genderwoman                             0.024408 *  
## applicant_educationnontrad                        0.004477 ** 
## applicant_genderwoman:applicant_educationnontrad  0.060548 .  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
ci_applicants <- coefci(m1, vcov. = m1$vcovHC_)
ci_applicants
##                                                        2.5 %      97.5 %
## (Intercept)                                       7.41963822  7.79023832
## applicant_genderwoman                             0.04194096  0.60605052
## applicant_educationnontrad                       -0.75563560 -0.13928031
## applicant_genderwoman:applicant_educationnontrad -0.86461727  0.01878228

In this case, we observe a significant effect of gender overall, but in the opposite direction which we expected. Women, on average, receive a higher rating than men (0.3239957 higher, p = 0.0244077). We also see a slight effect of education (p = 0.0044767). Specifically, the applicants with a nontraditional education background are rated -0.447458 lower than those with traditional educations. There is no interaction effect observed (p = 0.0605475).

Add Risk Aversion

m2 <- d[, lm(rating ~ applicant_gender * applicant_education + risk)]

# test for heteroscedasticity to determine if use of robust standard errors is justified
plot(m2)

bptest(m2)
## 
##  studentized Breusch-Pagan test
## 
## data:  m2
## BP = 24.62, df = 4, p-value = 5.999e-05
summary(m2)
## 
## Call:
## lm(formula = rating ~ applicant_gender * applicant_education + 
##     risk)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -6.1103 -0.9475  0.1020  1.0525  3.0176 
## 
## Coefficients:
##                                                  Estimate Std. Error t value
## (Intercept)                                       7.82269    0.31638  24.725
## applicant_genderwoman                             0.32279    0.16430   1.965
## applicant_educationnontrad                       -0.44841    0.15378  -2.916
## risk                                             -0.04950    0.06744  -0.734
## applicant_genderwoman:applicant_educationnontrad -0.40941    0.22830  -1.793
##                                                  Pr(>|t|)    
## (Intercept)                                       < 2e-16 ***
## applicant_genderwoman                             0.04977 *  
## applicant_educationnontrad                        0.00363 ** 
## risk                                              0.46314    
## applicant_genderwoman:applicant_educationnontrad  0.07326 .  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 1.714 on 911 degrees of freedom
## Multiple R-squared:  0.0386, Adjusted R-squared:  0.03438 
## F-statistic: 9.144 on 4 and 911 DF,  p-value: 3.031e-07
m2$vcovHC_ <- vcovHC(m2)
coefs_risk <- coeftest(m2, vcov. = m2$vcovHC_)
coefs_risk
## 
## t test of coefficients:
## 
##                                                   Estimate Std. Error t value
## (Intercept)                                       7.822693   0.328654 23.8022
## applicant_genderwoman                             0.322789   0.143967  2.2421
## applicant_educationnontrad                       -0.448411   0.157228 -2.8520
## risk                                             -0.049499   0.070949 -0.6977
## applicant_genderwoman:applicant_educationnontrad -0.409412   0.226607 -1.8067
##                                                   Pr(>|t|)    
## (Intercept)                                      < 2.2e-16 ***
## applicant_genderwoman                             0.025195 *  
## applicant_educationnontrad                        0.004443 ** 
## risk                                              0.485563    
## applicant_genderwoman:applicant_educationnontrad  0.071138 .  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
ci_risk <- coefci(m2, vcov. = m2$vcovHC_)
ci_risk
##                                                        2.5 %      97.5 %
## (Intercept)                                       7.17768578  8.46770028
## applicant_genderwoman                             0.04024293  0.60533414
## applicant_educationnontrad                       -0.75698235 -0.13983984
## risk                                             -0.18874190  0.08974395
## applicant_genderwoman:applicant_educationnontrad -0.85414388  0.03532005

We add risk aversion scores to the model to capture individual differences in regards to the amount of risk one may be confortable taking on. It does not change the estimations from the previous model.

Add Participant Gender

m3 <- d[, lm(rating ~ applicant_gender * applicant_education + risk + applicant_gender * factor(gender))]

# test for heteroscedasticity to determine if use of robust standard errors is justified
plot(m3)

bptest(m3)
## 
##  studentized Breusch-Pagan test
## 
## data:  m3
## BP = 29.243, df = 6, p-value = 5.472e-05
m3$vcovHC_ <- vcovHC(m3)
coefs_gender <- coeftest(m3, vcov. = m3$vcovHC_)
coefs_gender
## 
## t test of coefficients:
## 
##                                                   Estimate Std. Error t value
## (Intercept)                                       7.708639   0.331472 23.2557
## applicant_genderwoman                             0.442589   0.154948  2.8564
## applicant_educationnontrad                       -0.446486   0.156795 -2.8476
## risk                                             -0.026661   0.071787 -0.3714
## factor(gender)Woman                               0.056924   0.182739  0.3115
## applicant_genderwoman:applicant_educationnontrad -0.425120   0.227016 -1.8726
## applicant_genderwoman:factor(gender)Woman        -0.490556   0.284163 -1.7263
##                                                   Pr(>|t|)    
## (Intercept)                                      < 2.2e-16 ***
## applicant_genderwoman                             0.004383 ** 
## applicant_educationnontrad                        0.004505 ** 
## risk                                              0.710431    
## factor(gender)Woman                               0.755489    
## applicant_genderwoman:applicant_educationnontrad  0.061438 .  
## applicant_genderwoman:factor(gender)Woman         0.084630 .  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
ci_gender <- coefci(m3, vcov. = m3$vcovHC_)
ci_gender
##                                                       2.5 %      97.5 %
## (Intercept)                                       7.0580986  8.35917895
## applicant_genderwoman                             0.1384908  0.74668696
## applicant_educationnontrad                       -0.7542085 -0.13876451
## risk                                             -0.1675483  0.11422594
## factor(gender)Woman                              -0.3017156  0.41556348
## applicant_genderwoman:applicant_educationnontrad -0.8706555  0.02041629
## applicant_genderwoman:factor(gender)Woman        -1.0482485  0.06713614

Add Company Size

m4 <- d[, lm(rating ~ applicant_gender * applicant_education + risk + 
               applicant_gender * factor(gender)+
               factor(company_size))]

# test for heteroscedasticity to determine if use of robust standard errors is justified
plot(m4)

bptest(m4)
## 
##  studentized Breusch-Pagan test
## 
## data:  m4
## BP = 48.039, df = 10, p-value = 6.106e-07
m4$vcovHC_ <- vcovHC(m4)
coefs_company <- coeftest(m4, vcov. = m4$vcovHC_)
coefs_company
## 
## t test of coefficients:
## 
##                                                    Estimate Std. Error t value
## (Intercept)                                       7.8120332  0.3286516 23.7700
## applicant_genderwoman                             0.4605872  0.1524847  3.0205
## applicant_educationnontrad                       -0.4530964  0.1572225 -2.8819
## risk                                             -0.0209722  0.0721672 -0.2906
## factor(gender)Woman                              -0.0031159  0.1874127 -0.0166
## factor(company_size)100-500 employees            -0.4252463  0.1596861 -2.6630
## factor(company_size)50-100 employees             -0.1908751  0.2267440 -0.8418
## factor(company_size)500-1,000 employees           0.1479917  0.1664959  0.8889
## factor(company_size)Less than 50 employees       -0.1296298  0.1555929 -0.8331
## applicant_genderwoman:applicant_educationnontrad -0.4019270  0.2307918 -1.7415
## applicant_genderwoman:factor(gender)Woman        -0.4735862  0.2838319 -1.6685
##                                                   Pr(>|t|)    
## (Intercept)                                      < 2.2e-16 ***
## applicant_genderwoman                             0.002594 ** 
## applicant_educationnontrad                        0.004047 ** 
## risk                                              0.771419    
## factor(gender)Woman                               0.986739    
## factor(company_size)100-500 employees             0.007882 ** 
## factor(company_size)50-100 employees              0.400118    
## factor(company_size)500-1,000 employees           0.374314    
## factor(company_size)Less than 50 employees        0.404989    
## applicant_genderwoman:applicant_educationnontrad  0.081933 .  
## applicant_genderwoman:factor(gender)Woman         0.095554 .  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
ci_company <- coefci(m4, vcov. = m4$vcovHC_)
ci_company
##                                                       2.5 %      97.5 %
## (Intercept)                                       7.1670253  8.45704101
## applicant_genderwoman                             0.1613224  0.75985193
## applicant_educationnontrad                       -0.7616595 -0.14453326
## risk                                             -0.1626068  0.12066235
## factor(gender)Woman                              -0.3709299  0.36469814
## factor(company_size)100-500 employees            -0.7386445 -0.11184805
## factor(company_size)50-100 employees             -0.6358804  0.25413025
## factor(company_size)500-1,000 employees          -0.1787712  0.47475464
## factor(company_size)Less than 50 employees       -0.4349947  0.17573501
## applicant_genderwoman:applicant_educationnontrad -0.8548764  0.05102232
## applicant_genderwoman:factor(gender)Woman        -1.0306313  0.08345903

Add Years of Experience

m5 <- d[, lm(rating ~ applicant_gender * applicant_education + risk + 
               applicant_gender * factor(gender)+
               factor(company_size) +
               factor(experience) + age)]

# test for heteroscedasticity to determine if use of robust standard errors is justified
plot(m5)

bptest(m5)
## 
##  studentized Breusch-Pagan test
## 
## data:  m5
## BP = 52.771, df = 15, p-value = 4.208e-06
m5$vcovHC_ <- vcovHC(m5)
coefs_experience <- coeftest(m5, vcov. = m5$vcovHC_)
coefs_experience
## 
## t test of coefficients:
## 
##                                                    Estimate Std. Error t value
## (Intercept)                                       8.0531278  0.4838032 16.6455
## applicant_genderwoman                             0.4219646  0.1524217  2.7684
## applicant_educationnontrad                       -0.4757796  0.1588276 -2.9956
## risk                                             -0.0075750  0.0725459 -0.1044
## factor(gender)Woman                              -0.0668916  0.1919337 -0.3485
## factor(company_size)100-500 employees            -0.4457084  0.1607223 -2.7732
## factor(company_size)50-100 employees             -0.2279255  0.2250405 -1.0128
## factor(company_size)500-1,000 employees           0.1515464  0.1639368  0.9244
## factor(company_size)Less than 50 employees       -0.1316815  0.1549777 -0.8497
## factor(experience)1-2 years                      -0.0322101  0.2142429 -0.1503
## factor(experience)3-5 years                       0.2200940  0.1936681  1.1364
## factor(experience)5-10 years                      0.0196241  0.2009987  0.0976
## factor(experience)Less than 1 year                0.0180189  0.2383258  0.0756
## age                                              -0.0081335  0.0062059 -1.3106
## applicant_genderwoman:applicant_educationnontrad -0.3577721  0.2330602 -1.5351
## applicant_genderwoman:factor(gender)Woman        -0.4226884  0.2838550 -1.4891
##                                                   Pr(>|t|)    
## (Intercept)                                      < 2.2e-16 ***
## applicant_genderwoman                             0.005749 ** 
## applicant_educationnontrad                        0.002814 ** 
## risk                                              0.916862    
## factor(gender)Woman                               0.727536    
## factor(company_size)100-500 employees             0.005666 ** 
## factor(company_size)50-100 employees              0.311418    
## factor(company_size)500-1,000 employees           0.355516    
## factor(company_size)Less than 50 employees        0.395729    
## factor(experience)1-2 years                       0.880527    
## factor(experience)3-5 years                       0.256071    
## factor(experience)5-10 years                      0.922245    
## factor(experience)Less than 1 year                0.939749    
## age                                               0.190327    
## applicant_genderwoman:applicant_educationnontrad  0.125109    
## applicant_genderwoman:factor(gender)Woman         0.136811    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
ci_experience <- coefci(m5, vcov. = m5$vcovHC_)
ci_experience
##                                                        2.5 %       97.5 %
## (Intercept)                                       7.10361405  9.002641526
## applicant_genderwoman                             0.12282130  0.721107923
## applicant_educationnontrad                       -0.78749516 -0.164063965
## risk                                             -0.14995393  0.134803873
## factor(gender)Woman                              -0.44358140  0.309798206
## factor(company_size)100-500 employees            -0.76114249 -0.130274373
## factor(company_size)50-100 employees             -0.66959066  0.213739635
## factor(company_size)500-1,000 employees          -0.17019655  0.473289354
## factor(company_size)Less than 50 employees       -0.43584117  0.172478199
## factor(experience)1-2 years                      -0.45268390  0.388263687
## factor(experience)3-5 years                      -0.15999958  0.600187538
## factor(experience)5-10 years                     -0.37485652  0.414104759
## factor(experience)Less than 1 year               -0.44972009  0.485757940
## age                                              -0.02031331  0.004046291
## applicant_genderwoman:applicant_educationnontrad -0.81517678  0.099632488
## applicant_genderwoman:factor(gender)Woman        -0.97978314  0.134406348

Now that we have included all covariates, we can interpret this model & examine the role of applicant gender and education, as well as the role of the various covariates.

Model Comparison

anova(m1, m2, m3, m4, m5)
## Analysis of Variance Table
## 
## Model 1: rating ~ applicant_gender * applicant_education
## Model 2: rating ~ applicant_gender * applicant_education + risk
## Model 3: rating ~ applicant_gender * applicant_education + risk + applicant_gender * 
##     factor(gender)
## Model 4: rating ~ applicant_gender * applicant_education + risk + applicant_gender * 
##     factor(gender) + factor(company_size)
## Model 5: rating ~ applicant_gender * applicant_education + risk + applicant_gender * 
##     factor(gender) + factor(company_size) + factor(experience) + 
##     age
##   Res.Df    RSS Df Sum of Sq      F  Pr(>F)  
## 1    912 2677.0                              
## 2    911 2675.4  1     1.582 0.5453 0.46043  
## 3    909 2661.4  2    14.055 2.4220 0.08932 .
## 4    905 2627.6  4    33.778 2.9104 0.02076 *
## 5    900 2611.3  5    16.259 1.1208 0.34756  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
stargazer(
  m1, 
  m2,
  m3,
  m4,
  m5,
  type = 'html',
  se = list(sqrt(diag(m1$vcovHC_)),
            sqrt(diag(m2$vcovHC_)),
            sqrt(diag(m3$vcovHC_)),
            sqrt(diag(m4$vcovHC_)),
            sqrt(diag(m5$vcovHC_))
  ),
 # header=FALSE,
  single.row = TRUE, 
  no.space = TRUE 
)
## 
## <table style="text-align:center"><tr><td colspan="6" style="border-bottom: 1px solid black"></td></tr><tr><td style="text-align:left"></td><td colspan="5"><em>Dependent variable:</em></td></tr>
## <tr><td></td><td colspan="5" style="border-bottom: 1px solid black"></td></tr>
## <tr><td style="text-align:left"></td><td colspan="5">rating</td></tr>
## <tr><td style="text-align:left"></td><td>(1)</td><td>(2)</td><td>(3)</td><td>(4)</td><td>(5)</td></tr>
## <tr><td colspan="6" style="border-bottom: 1px solid black"></td></tr><tr><td style="text-align:left">applicant_genderwoman</td><td>0.324<sup>**</sup> (0.144)</td><td>0.323<sup>**</sup> (0.144)</td><td>0.443<sup>***</sup> (0.155)</td><td>0.461<sup>***</sup> (0.152)</td><td>0.422<sup>***</sup> (0.152)</td></tr>
## <tr><td style="text-align:left">applicant_educationnontrad</td><td>-0.447<sup>***</sup> (0.157)</td><td>-0.448<sup>***</sup> (0.157)</td><td>-0.446<sup>***</sup> (0.157)</td><td>-0.453<sup>***</sup> (0.157)</td><td>-0.476<sup>***</sup> (0.159)</td></tr>
## <tr><td style="text-align:left">risk</td><td></td><td>-0.049 (0.071)</td><td>-0.027 (0.072)</td><td>-0.021 (0.072)</td><td>-0.008 (0.073)</td></tr>
## <tr><td style="text-align:left">factor(gender)Woman</td><td></td><td></td><td>0.057 (0.183)</td><td>-0.003 (0.187)</td><td>-0.067 (0.192)</td></tr>
## <tr><td style="text-align:left">factor(company_size)100-500 employees</td><td></td><td></td><td></td><td>-0.425<sup>***</sup> (0.160)</td><td>-0.446<sup>***</sup> (0.161)</td></tr>
## <tr><td style="text-align:left">factor(company_size)50-100 employees</td><td></td><td></td><td></td><td>-0.191 (0.227)</td><td>-0.228 (0.225)</td></tr>
## <tr><td style="text-align:left">factor(company_size)500-1,000 employees</td><td></td><td></td><td></td><td>0.148 (0.166)</td><td>0.152 (0.164)</td></tr>
## <tr><td style="text-align:left">factor(company_size)Less than 50 employees</td><td></td><td></td><td></td><td>-0.130 (0.156)</td><td>-0.132 (0.155)</td></tr>
## <tr><td style="text-align:left">factor(experience)1-2 years</td><td></td><td></td><td></td><td></td><td>-0.032 (0.214)</td></tr>
## <tr><td style="text-align:left">factor(experience)3-5 years</td><td></td><td></td><td></td><td></td><td>0.220 (0.194)</td></tr>
## <tr><td style="text-align:left">factor(experience)5-10 years</td><td></td><td></td><td></td><td></td><td>0.020 (0.201)</td></tr>
## <tr><td style="text-align:left">factor(experience)Less than 1 year</td><td></td><td></td><td></td><td></td><td>0.018 (0.238)</td></tr>
## <tr><td style="text-align:left">age</td><td></td><td></td><td></td><td></td><td>-0.008 (0.006)</td></tr>
## <tr><td style="text-align:left">applicant_genderwoman:applicant_educationnontrad</td><td>-0.423<sup>*</sup> (0.225)</td><td>-0.409<sup>*</sup> (0.227)</td><td>-0.425<sup>*</sup> (0.227)</td><td>-0.402<sup>*</sup> (0.231)</td><td>-0.358 (0.233)</td></tr>
## <tr><td style="text-align:left">applicant_genderwoman:factor(gender)Woman</td><td></td><td></td><td>-0.491<sup>*</sup> (0.284)</td><td>-0.474<sup>*</sup> (0.284)</td><td>-0.423 (0.284)</td></tr>
## <tr><td style="text-align:left">Constant</td><td>7.605<sup>***</sup> (0.094)</td><td>7.823<sup>***</sup> (0.329)</td><td>7.709<sup>***</sup> (0.331)</td><td>7.812<sup>***</sup> (0.329)</td><td>8.053<sup>***</sup> (0.484)</td></tr>
## <tr><td colspan="6" style="border-bottom: 1px solid black"></td></tr><tr><td style="text-align:left">Observations</td><td>916</td><td>916</td><td>916</td><td>916</td><td>916</td></tr>
## <tr><td style="text-align:left">R<sup>2</sup></td><td>0.038</td><td>0.039</td><td>0.044</td><td>0.056</td><td>0.062</td></tr>
## <tr><td style="text-align:left">Adjusted R<sup>2</sup></td><td>0.035</td><td>0.034</td><td>0.037</td><td>0.045</td><td>0.046</td></tr>
## <tr><td style="text-align:left">Residual Std. Error</td><td>1.713 (df = 912)</td><td>1.714 (df = 911)</td><td>1.711 (df = 909)</td><td>1.704 (df = 905)</td><td>1.703 (df = 900)</td></tr>
## <tr><td style="text-align:left">F Statistic</td><td>12.019<sup>***</sup> (df = 3; 912)</td><td>9.144<sup>***</sup> (df = 4; 911)</td><td>6.915<sup>***</sup> (df = 6; 909)</td><td>5.347<sup>***</sup> (df = 10; 905)</td><td>3.941<sup>***</sup> (df = 15; 900)</td></tr>
## <tr><td colspan="6" style="border-bottom: 1px solid black"></td></tr><tr><td style="text-align:left"><em>Note:</em></td><td colspan="5" style="text-align:right"><sup>*</sup>p<0.1; <sup>**</sup>p<0.05; <sup>***</sup>p<0.01</td></tr>
## </table>

Predict Scale Measures

We also collected scale responses to indicate further which aspects of an applicant may be supporting the rating provided. Here, we conduct exploratory analysis to examine how the factors of an application may also influence the ratings of these scales. In this case, we do not examine covariates. This is to limit the amount of significance testing performed in these exploratory models. We do not state any causal claims, but rather use these models to indicate possible explanations for differences in overall ratings between different genders and education backgrounds.

m_technical <- d[, lm(technical_scale ~ applicant_gender * applicant_education)]

m_technical$vcovHC_ <- vcovHC(m_technical)
coefs_technical <- coeftest(m_technical, vcov. = m_technical$vcovHC_)
coefs_technical
## 
## t test of coefficients:
## 
##                                                   Estimate Std. Error t value
## (Intercept)                                       7.765432   0.085451 90.8756
## applicant_genderwoman                             0.193959   0.143420  1.3524
## applicant_educationnontrad                       -0.332361   0.140844 -2.3598
## applicant_genderwoman:applicant_educationnontrad -0.455858   0.218620 -2.0852
##                                                  Pr(>|t|)    
## (Intercept)                                       < 2e-16 ***
## applicant_genderwoman                             0.17659    
## applicant_educationnontrad                        0.01850 *  
## applicant_genderwoman:applicant_educationnontrad  0.03733 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
ggplot(analysis, aes(y = technical_scale, x = applicant_education))+
  geom_jitter(aes(color = Condition), alpha = 0.5)+
  geom_boxplot(alpha = 0.8, aes(fill = Condition))+
  scale_fill_manual(values = color_scheme)+
  scale_color_manual(values = color_scheme)+
  scale_x_discrete(labels = c("Traditional", "Non-Traditional"))+
  labs(title = "Comparison of Technical Ratings between Conditions",
       y = "Technical Scale Rating\n",
       x = "\nApplicant Education")+
  theme(legend.position = "none")

m_leadership <- d[, lm(leadership_scale ~ applicant_gender * applicant_education)]

m_leadership$vcovHC_ <- vcovHC(m_leadership)
coefs_leadership <- coeftest(m_leadership, vcov. = m_leadership$vcovHC_)
coefs_leadership
## 
## t test of coefficients:
## 
##                                                   Estimate Std. Error t value
## (Intercept)                                       6.358025   0.110405 57.5882
## applicant_genderwoman                             0.093752   0.185581  0.5052
## applicant_educationnontrad                       -0.251725   0.158810 -1.5851
## applicant_genderwoman:applicant_educationnontrad -0.087439   0.248611 -0.3517
##                                                  Pr(>|t|)    
## (Intercept)                                        <2e-16 ***
## applicant_genderwoman                              0.6136    
## applicant_educationnontrad                         0.1133    
## applicant_genderwoman:applicant_educationnontrad   0.7251    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
ggplot(analysis, aes(y = leadership_scale, x = applicant_education))+
  geom_jitter(aes(color = Condition), alpha = 0.5)+
  geom_boxplot(alpha = 0.8, aes(fill = Condition))+
  scale_fill_manual(values = color_scheme)+
  scale_color_manual(values = color_scheme)+
  scale_x_discrete(labels = c("Traditional", "Non-Traditional"))+
  labs(title = "Comparison of Leadership Ratings between Conditions",
       y = "Leadership Scale Rating\n",
       x = "\nApplicant Education")+
  theme(legend.position = "none")

m_likeable <- d[, lm(likeable_scale ~ applicant_gender * applicant_education)]

m_likeable$vcovHC_ <- vcovHC(m_likeable)
coefs_likeable <- coeftest(m_likeable, vcov. = m_likeable$vcovHC_)
coefs_likeable
## 
## t test of coefficients:
## 
##                                                   Estimate Std. Error t value
## (Intercept)                                       6.526749   0.107959 60.4556
## applicant_genderwoman                             0.666144   0.176476  3.7747
## applicant_educationnontrad                       -0.054308   0.153863 -0.3530
## applicant_genderwoman:applicant_educationnontrad -0.260207   0.232661 -1.1184
##                                                   Pr(>|t|)    
## (Intercept)                                      < 2.2e-16 ***
## applicant_genderwoman                            0.0001706 ***
## applicant_educationnontrad                       0.7241981    
## applicant_genderwoman:applicant_educationnontrad 0.2636921    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
ggplot(analysis, aes(y = likeable_scale, x = applicant_education))+
  geom_jitter(aes(color = Condition), alpha = 0.5)+
  geom_boxplot(alpha = 0.8, aes(fill = Condition))+
  scale_fill_manual(values = color_scheme)+
  scale_color_manual(values = color_scheme)+
  scale_x_discrete(labels = c("Traditional", "Non-Traditional"))+
  labs(title = "Comparison of Likeability Ratings between Conditions",
       y = "Likeability Scale Rating\n",
       x = "\nApplicant Education")+
  theme(legend.position = "none")

m_learner <- d[, lm(learner_scale ~ applicant_gender * applicant_education)]

m_learner$vcovHC_ <- vcovHC(m_learner)
coefs_learner <- coeftest(m_learner, vcov. = m_learner$vcovHC_)
coefs_learner
## 
## t test of coefficients:
## 
##                                                   Estimate Std. Error t value
## (Intercept)                                       6.855967   0.091653 74.8031
## applicant_genderwoman                             0.336926   0.163375  2.0623
## applicant_educationnontrad                       -0.044943   0.139332 -0.3226
## applicant_genderwoman:applicant_educationnontrad -0.337139   0.221099 -1.5248
##                                                  Pr(>|t|)    
## (Intercept)                                       < 2e-16 ***
## applicant_genderwoman                             0.03946 *  
## applicant_educationnontrad                        0.74710    
## applicant_genderwoman:applicant_educationnontrad  0.12765    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
ggplot(analysis, aes(y = learner_scale, x = applicant_education))+
  geom_jitter(aes(color = Condition), alpha = 0.5)+
  geom_boxplot(alpha = 0.8, aes(fill = Condition))+
  scale_fill_manual(values = color_scheme)+
  scale_color_manual(values = color_scheme)+
  scale_x_discrete(labels = c("Traditional", "Non-Traditional"))+
  labs(title = "Comparison of Quick Learner Ratings between Conditions",
       y = "Quick Learner Scale Rating\n",
       x = "\nApplicant Education")+
  theme(legend.position = "none")

m_education <- d[, lm(education_scale ~ applicant_gender * applicant_education)]

m_education$vcovHC_ <- vcovHC(m_education)
coefs_education <- coeftest(m_education, vcov. = m_education$vcovHC_)
coefs_education
## 
## t test of coefficients:
## 
##                                                   Estimate Std. Error  t value
## (Intercept)                                       7.987654   0.094678  84.3666
## applicant_genderwoman                             0.210315   0.140805   1.4937
## applicant_educationnontrad                       -2.113639   0.199506 -10.5943
## applicant_genderwoman:applicant_educationnontrad -0.291538   0.294396  -0.9903
##                                                  Pr(>|t|)    
## (Intercept)                                        <2e-16 ***
## applicant_genderwoman                              0.1356    
## applicant_educationnontrad                         <2e-16 ***
## applicant_genderwoman:applicant_educationnontrad   0.3223    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
ggplot(analysis, aes(y = education_scale, x = applicant_education))+
  geom_jitter(aes(color = Condition), alpha = 0.5)+
  geom_boxplot(alpha = 0.8, aes(fill = Condition))+
  scale_fill_manual(values = color_scheme)+
  scale_color_manual(values = color_scheme)+
  scale_x_discrete(labels = c("Traditional", "Non-Traditional"))+
  labs(title = "Comparison of Relevant Education Ratings between Conditions",
       y = "Relevant Education Scale Rating\n",
       x = "\nApplicant Education")+
  theme(legend.position = "none")

m_experience <- d[, lm(experience_scale ~ applicant_gender * applicant_education)]

m_experience$vcovHC_ <- vcovHC(m_experience)
coefs_experience <- coeftest(m_experience, vcov. = m_experience$vcovHC_)
coefs_experience
## 
## t test of coefficients:
## 
##                                                   Estimate Std. Error t value
## (Intercept)                                       7.847737   0.094172 83.3341
## applicant_genderwoman                             0.319776   0.148412  2.1546
## applicant_educationnontrad                       -0.087894   0.137263 -0.6403
## applicant_genderwoman:applicant_educationnontrad -0.795835   0.217477 -3.6594
##                                                   Pr(>|t|)    
## (Intercept)                                      < 2.2e-16 ***
## applicant_genderwoman                            0.0314507 *  
## applicant_educationnontrad                       0.5221171    
## applicant_genderwoman:applicant_educationnontrad 0.0002673 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
ggplot(analysis, aes(y = experience_scale, x = applicant_education))+
  geom_jitter(aes(color = Condition), alpha = 0.5)+
  geom_boxplot(alpha = 0.8, aes(fill = Condition))+
  scale_fill_manual(values = color_scheme)+
  scale_color_manual(values = color_scheme)+
  scale_x_discrete(labels = c("Traditional", "Non-Traditional"))+
  labs(title = "Comparison of Relevant Experience Ratings between Conditions",
       y = "Relevant Experience Scale Rating\n",
       x = "\nApplicant Education")+
  theme(legend.position = "none")

stargazer(
  m_technical, 
  m_leadership,
  m_likeable,
  m_learner,
  m_education,
  m_experience,
  type = 'html',
  se = list(sqrt(diag(m_technical$vcovHC_)),
            sqrt(diag(m_leadership$vcovHC_)),
            sqrt(diag(m_likeable$vcovHC_)),
            sqrt(diag(m_learner$vcovHC_)),
            sqrt(diag(m_education$vcovHC_)),
            sqrt(diag(m_experience$vcovHC_))
  ),
 # header=FALSE,
  single.row = TRUE, 
  no.space = TRUE 
)
## 
## <table style="text-align:center"><tr><td colspan="7" style="border-bottom: 1px solid black"></td></tr><tr><td style="text-align:left"></td><td colspan="6"><em>Dependent variable:</em></td></tr>
## <tr><td></td><td colspan="6" style="border-bottom: 1px solid black"></td></tr>
## <tr><td style="text-align:left"></td><td>technical_scale</td><td>leadership_scale</td><td>likeable_scale</td><td>learner_scale</td><td>education_scale</td><td>experience_scale</td></tr>
## <tr><td style="text-align:left"></td><td>(1)</td><td>(2)</td><td>(3)</td><td>(4)</td><td>(5)</td><td>(6)</td></tr>
## <tr><td colspan="7" style="border-bottom: 1px solid black"></td></tr><tr><td style="text-align:left">applicant_genderwoman</td><td>0.194 (0.143)</td><td>0.094 (0.186)</td><td>0.666<sup>***</sup> (0.176)</td><td>0.337<sup>**</sup> (0.163)</td><td>0.210 (0.141)</td><td>0.320<sup>**</sup> (0.148)</td></tr>
## <tr><td style="text-align:left">applicant_educationnontrad</td><td>-0.332<sup>**</sup> (0.141)</td><td>-0.252 (0.159)</td><td>-0.054 (0.154)</td><td>-0.045 (0.139)</td><td>-2.114<sup>***</sup> (0.200)</td><td>-0.088 (0.137)</td></tr>
## <tr><td style="text-align:left">applicant_genderwoman:applicant_educationnontrad</td><td>-0.456<sup>**</sup> (0.219)</td><td>-0.087 (0.249)</td><td>-0.260 (0.233)</td><td>-0.337 (0.221)</td><td>-0.292 (0.294)</td><td>-0.796<sup>***</sup> (0.217)</td></tr>
## <tr><td style="text-align:left">Constant</td><td>7.765<sup>***</sup> (0.085)</td><td>6.358<sup>***</sup> (0.110)</td><td>6.527<sup>***</sup> (0.108)</td><td>6.856<sup>***</sup> (0.092)</td><td>7.988<sup>***</sup> (0.095)</td><td>7.848<sup>***</sup> (0.094)</td></tr>
## <tr><td colspan="7" style="border-bottom: 1px solid black"></td></tr><tr><td style="text-align:left">Observations</td><td>916</td><td>916</td><td>916</td><td>916</td><td>916</td><td>916</td></tr>
## <tr><td style="text-align:left">R<sup>2</sup></td><td>0.031</td><td>0.006</td><td>0.026</td><td>0.009</td><td>0.199</td><td>0.034</td></tr>
## <tr><td style="text-align:left">Adjusted R<sup>2</sup></td><td>0.028</td><td>0.003</td><td>0.023</td><td>0.005</td><td>0.196</td><td>0.031</td></tr>
## <tr><td style="text-align:left">Residual Std. Error (df = 912)</td><td>1.641</td><td>1.845</td><td>1.732</td><td>1.638</td><td>2.264</td><td>1.626</td></tr>
## <tr><td style="text-align:left">F Statistic (df = 3; 912)</td><td>9.802<sup>***</sup></td><td>1.988</td><td>8.209<sup>***</sup></td><td>2.626<sup>**</sup></td><td>75.350<sup>***</sup></td><td>10.710<sup>***</sup></td></tr>
## <tr><td colspan="7" style="border-bottom: 1px solid black"></td></tr><tr><td style="text-align:left"><em>Note:</em></td><td colspan="6" style="text-align:right"><sup>*</sup>p<0.1; <sup>**</sup>p<0.05; <sup>***</sup>p<0.01</td></tr>
## </table>

Other Visualizations

ggplot(subset(analysis, gender == "Man" | gender == "Woman"), aes(y = rating, x = applicant_gender))+
  geom_jitter(aes(color = gender), alpha = 0.8)+
  scale_color_manual(values = c(m_t, w_t))+
  geom_boxplot(alpha = 0.8, aes(fill = gender))+
  scale_fill_manual(values = c(m_t, w_t))+
  facet_grid(.~ gender)